package com.ruoyi.customerOrder.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.customerOrder.mapper.CustomerOrderMapper;
import com.ruoyi.customerOrder.domain.CustomerOrder;
import com.ruoyi.customerOrder.service.ICustomerOrderService;

/**
 * 订单管理Service业务层处理
 * 
 * @author wxl
 * @date 2023-11-11
 */
@Service
public class CustomerOrderServiceImpl implements ICustomerOrderService 
{
    @Autowired
    private CustomerOrderMapper customerOrderMapper;

    /**
     * 查询订单管理
     * 
     * @param orderId 订单管理主键
     * @return 订单管理
     */
    @Override
    public CustomerOrder selectCustomerOrderByOrderId(Long orderId)
    {
        return customerOrderMapper.selectCustomerOrderByOrderId(orderId);
    }

    /**
     * 查询订单管理列表
     * 
     * @param customerOrder 订单管理
     * @return 订单管理
     */
    @Override
    public List<CustomerOrder> selectCustomerOrderList(CustomerOrder customerOrder)
    {
        return customerOrderMapper.selectCustomerOrderList(customerOrder);
    }

    /**
     * 新增订单管理
     * 
     * @param customerOrder 订单管理
     * @return 结果
     */
    @Override
    public int insertCustomerOrder(CustomerOrder customerOrder)
    {
        return customerOrderMapper.insertCustomerOrder(customerOrder);
    }

    /**
     * 修改订单管理
     * 
     * @param customerOrder 订单管理
     * @return 结果
     */
    @Override
    public int updateCustomerOrder(CustomerOrder customerOrder)
    {
        return customerOrderMapper.updateCustomerOrder(customerOrder);
    }

    /**
     * 批量删除订单管理
     * 
     * @param orderIds 需要删除的订单管理主键
     * @return 结果
     */
    @Override
    public int deleteCustomerOrderByOrderIds(Long[] orderIds)
    {
        return customerOrderMapper.deleteCustomerOrderByOrderIds(orderIds);
    }

    /**
     * 删除订单管理信息
     * 
     * @param orderId 订单管理主键
     * @return 结果
     */
    @Override
    public int deleteCustomerOrderByOrderId(Long orderId)
    {
        return customerOrderMapper.deleteCustomerOrderByOrderId(orderId);
    }
}
